package com.prj.ufdm.cloud.ms.test.enums;

/**
 * DESC: JSON 对象类型 <br>
 * @author 胡义振
 * @date 2020年2月28日
 */
public enum JsonObjectTypeEnum {
	
	JSON_OBJECT("JSON_OBJECT","对象类型"),
	JSON_ARRAY("JSON_ARRAY","数组类型"),
	JSON_OTHER("JSON_OTHER","其他类型");
	
	private String code;
	private String message;
	
	JsonObjectTypeEnum(String code,String message){
		this.code = code;
		this.message = message;
	}

	public static String getRetMessage(String retCode){
		String rtnRetCode = "";
		for (JsonObjectTypeEnum coreRetCodeEnum : JsonObjectTypeEnum.values()) {
			if(coreRetCodeEnum.code.equals(retCode)){
				rtnRetCode = coreRetCodeEnum.message;
			}
	    }
		return rtnRetCode;
	}

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public String getMessage() {
		return message;
	}

	public void setMessage(String message) {
		this.message = message;
	}
}
